package com.superm.mappers;

import com.superm.entity.ShelfApplication;
import org.apache.ibatis.annotations.Param;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

/**
 * 上架申请单接口
 */
public interface ShelfApplicationMapper {


    /**
     * 申请单添加
     * @param shelfApplication
     * @return
     */
    int addRequistion(@Param("shelfApplication") ShelfApplication shelfApplication);


    /**
     * 模糊查询全部信息
     * @param shelfApplication
     * @return
     */
    List<ShelfApplication> selectMationInfo(@Param("shelfApplication")  ShelfApplication shelfApplication,@Param("pageNo")Integer pageNo,@Param("pageSize")Integer pageSize);


    //模糊查询条数
    int selectCount(@Param("shelfApplication")  ShelfApplication shelfApplication);

    /**
     * 根据指定订单号查询订单信息
     * @param sapplicationCode
     * @return
     */
    ShelfApplication selectCodeMationInfo(@Param("sapplicationCode") String sapplicationCode);
    /**
     * 改变状态为已审批
     * @return
     */
    int updateState1(@Param("sapplicationCode") String sapplicationCode);


    /**
     * 修改状态驳回
     * @param shelfApplication
     * @return
     */
    int updateState4(@Param("shelfApplication")ShelfApplication shelfApplication);


    /**
     * 修改状态已出库
     * @param sapplicationCode
     * @return
     */
    int updateState2(@Param("sapplicationCode") String sapplicationCode);


    /**
     *  修改状态已上架
     * @param sapplicationCode
     * @return
     */
    int updateState3(@Param("sapplicationCode") String sapplicationCode);

    
}
